package com.zmn.oms.zmn.business.interfaces.quotation3;

import com.zmn.common.dto2.ResponseDTO;
import com.zmn.oms.common.dio.quotation3.*;
import com.zmn.oms.common.dro.quotation3.OperateResultDRO;
import com.zmn.oms.common.dto.OmsOperator;
import com.zmn.oms.common.exception.OmsBaseException;
import com.zmn.oms.model.entity.work.OrderWork;
import io.swagger.annotations.ApiOperation;

/**
 * @author sunlife
 * @date:2021/12/1 6:44 下午
 * description:
 */
public interface OrderQuotation3ModifyBService {

    /**
     * 开始检修
     */
    void startCheck(OmsOperator operator) throws OmsBaseException;

    /**
     * 确认故障检修方式
     * @param dio
     * @throws OmsBaseException
     */
    OperateResultDRO confirmCheckType(ConfirmCheckTypeDIO dio) throws OmsBaseException;

    /**
     * 确认故障信息
     */
    OperateResultDRO confirmFaultInfo(ConfirmFaultInfoDIO confirmFaultInfoDIO) throws OmsBaseException;

    /**
     * 提交检测报告
     * @param checkReportDIO
     */
    void submitCheckReport(CheckReportDIO checkReportDIO) throws OmsBaseException;

    /**
     * 清理报价数据
     * @param orderId
     * @param workId
     * @param isDeepClean 是否是确认故障信息
     */
    void clearQuotationInfo(Long orderId, Long workId, boolean isDeepClean) throws OmsBaseException;

    /**
     * 工程师确认检测报告
     */
    @ApiOperation("工程师确认检测报告")
    void confirmCheckReportByEngineer(ConfirmCheckReportDIO confirmCheckReportDIO) throws OmsBaseException;

    /**
     * 确认是否同意维修
     */
    @ApiOperation(value = "工程师操作是否同意维修")
    void submitConfirmRepairResultByEngineer(ConfirmRepairDIO confirmRepairDIO) throws OmsBaseException;

    /**
     * 发送同意验收验证码
     */
    @ApiOperation(value = "发送同意验收验证码")
    void sendCaptcha(SendAgreeCapthaDIO sendAgreeCapthaDIO) throws OmsBaseException;


    /**
     * 确认是否同意维修
     */
    @ApiOperation(value = "确认是否同意维修", notes = "用户、工程师均可以使用此接口")
    void submitConfirmRepairResult(ConfirmRepairDIO confirmRepairDIO) throws OmsBaseException;


    /**
     * 确认是否同意维修
     */
    @ApiOperation(value = "通过验证码确认是否同意维修", notes = "用户、工程师均可以使用此接口")
    void submitConfirmRepairResultWithCaptcha(ConfirmRepairDIO confirmRepairDIO) throws OmsBaseException;

    /**
     * 给用户发送故障确认小心
     * @param operator
     */
    void sendFaultConfirmMessage(OmsOperator operator) throws OmsBaseException;

    /**
     * 工程师确认用户是否同意维修
     * @param confirmRepairDIO
     */
    void confirmUserAgreeResultByEngineer(ConfirmRepairDIO confirmRepairDIO) throws OmsBaseException;

    /**
     * 使用工程师优惠
     * @param engineerDiscountDIO
     */
    String addDiscountByEngineer(EngineerDiscountDIO engineerDiscountDIO) throws OmsBaseException ;

    /**
     * 使用工程师优惠
     * @param engineerDiscountDIO
     */
    void useEngineerDiscount(EngineerDiscountDIO engineerDiscountDIO) throws OmsBaseException ;

    /**
     * 保存人工优惠
     * @param artificialDiscountDIO
     */
    void saveDiscount(ArtificialDiscountDIO artificialDiscountDIO) throws OmsBaseException;

    /**
     * 使用工程师优惠
     * @param mobileDIO
     */
    void sendDiscountToUser(MobileDIO mobileDIO) throws OmsBaseException ;

    /**
     * 添加工程师验收检测项目
     * @param addOrderAcceptMaintainDIO
     */
    void addOrderAcceptMaintainItem(AddOrderAcceptMaintainDIO addOrderAcceptMaintainDIO);

    /**
     * 提交故障码
     * @param submitFaultCodeDIO
     */
    OperateResultDRO submitFaultCode(SubmitFaultCodeDIO submitFaultCodeDIO) throws OmsBaseException;

    /**
     * 删除工程师优惠
     *
     * @param orderWork
     * @param isClearDiscountId 是否删除 优惠券
     * @return 删除成功
     */
    boolean clearEngineerDiscount(OrderWork orderWork, boolean isClearDiscountId) throws OmsBaseException;


}
